package com.aop.springbootaop.service;

import com.aop.springbootaop.entity.User;
import com.aop.springbootaop.mapper.UserMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserMysqlService {
    @Autowired
    private UserMapper userMapper;

    public User getUserById(Long id) {
        return userMapper.selectUserById(id);
    }

    public List<User> selectUserByPage(int pageNo, int pageSize) {
        return userMapper.selectUserByPage(pageNo,pageSize);
    }
}
